package com.mengmeng.demo.service.impl;

import com.mengmeng.demo.mapper.TokenMapper;
import com.mengmeng.demo.user.token;
import com.mengmeng.demo.service.TokenService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

// 接口实现类
@Service
public class TokenServiceImpl implements TokenService {
    @Autowired
    TokenMapper tokenMapper;



    @Override
    public List<token> getAllto() {
        return tokenMapper.getAllto();
    }

    @Override
    public boolean deleteto(Integer token) {
        return tokenMapper.deleteBytoken(token);
    }

    @Override
    public boolean updateto(token to) {
        return tokenMapper.updateto(to);
    }

    @Override
    public boolean inserteto(token to) {
        return tokenMapper.insertto(to);
    }

    @Override
    public List<token> getBytoken(int token) {
        return tokenMapper.getBytoken(token);
    }
}
